#include <conio.h>
#include <cmath>
#include <iostream>
using namespace std;
class Polynomial
{
	int degree;
	double *coeff;
public:
	Polynomial();
	Polynomial(int);
	Polynomial(int, double *);
	void print();
	void nhap();
	Polynomial& operator=(const Polynomial &);
	friend Polynomial operator+(const Polynomial &,const Polynomial &);
	friend Polynomial operator-(const Polynomial &,const Polynomial &);
	friend Polynomial operator*(const Polynomial &,const Polynomial &);
	friend Polynomial operator/(const Polynomial &,const Polynomial &);
	double operator()(const int);
	double operator[](const int);
	friend ostream & operator<<(ostream &,const Polynomial &);
	friend istream & operator>>(istream &,Polynomial &);
	
};
